Manages the render queues available in the component. More...
Public Member Functions | |
~RenderQueueManager () | |
RenderQueue * | createOrRetrieve (int index=-1) |
RenderQueue * | createOrRetrieve (const nkMemory::StringView &name) |
RenderQueue * | get (unsigned int index) const |
RenderQueue * | get (const nkMemory::StringView &name) const |
RenderQueue * | getByIndex (unsigned int indexGlobal) const |
RenderQueue * | getNamedByIndex (unsigned int indexGlobal) const |
void | rename (const nkMemory::StringView &oldName, const nkMemory::StringView &newName) |
void | erase (const nkMemory::StringView &name) |
void | updateRenderingQueue (int minRQ, int maxRQ) |
void | updateRenderingQueue (const nkMemory::StringView &name) |
void | updateRenderingQueue (RenderQueue *fromThisOne) |
RenderQueue * | getComputedRenderingQueue () const |
Manages the render queues available in the component.
The manager owns the memory it allocates. External code should not delete it.
nkGraphics::RenderQueueManager::~RenderQueueManager | ( | ) |
Destructor.
RenderQueue* nkGraphics::RenderQueueManager::createOrRetrieve | ( | int | index = -1 | ) |
Creates if unavailable, or retrieves if available, a render queue.
index | The numerical index of the queue to retrieve. |
RenderQueue* nkGraphics::RenderQueueManager::createOrRetrieve | ( | const nkMemory::StringView & | name | ) |
Creates if unavailable, or retrieves if available, a render queue.
name | The name of the queue to retrieve. |
RenderQueue* nkGraphics::RenderQueueManager::get | ( | unsigned int | index | ) | const |
Retrieves a queue.
index | The numerical index of the queue to retrieve. |
RenderQueue* nkGraphics::RenderQueueManager::get | ( | const nkMemory::StringView & | name | ) | const |
Retrieves a queue.
name | The name of the queue to retrieve. |
RenderQueue* nkGraphics::RenderQueueManager::getByIndex | ( | unsigned int | indexGlobal | ) | const |
Retrieves a render queue given an index, fetching indexed queues and named queues. Note that as the internal memory is changed, an index can map to different resources over different calls. Mainly used to loop over all queues in one go.
indexGlobal | The index of the queue to retrieve. |
RenderQueue* nkGraphics::RenderQueueManager::getNamedByIndex | ( | unsigned int | indexGlobal | ) | const |
Retrieves a named queue, by index. Note that an index can point to different queues as the memory gets changed. Mainly used to loop over all named render queues in one go.
indexGlobal | The index of the queue to retrieve. |
void nkGraphics::RenderQueueManager::rename | ( | const nkMemory::StringView & | oldName, |
const nkMemory::StringView & | newName | ||
) |
Renames a queue, changing both its name and the way to access it within the manager.
oldName | The name of the queue to change. |
newName | The name to rename it to. |
void nkGraphics::RenderQueueManager::erase | ( | const nkMemory::StringView & | name | ) |
Erases and frees the memory of a render queue.
name | The name of the render queue to erase. |
void nkGraphics::RenderQueueManager::updateRenderingQueue | ( | int | minRQ, |
int | maxRQ | ||
) |
Updates the rendering queue. Used internally in the rendering process.
minRQ | The minimum index of the queue that will serve as base. |
maxRQ | The maximum index of the queue that will serve as base. |
void nkGraphics::RenderQueueManager::updateRenderingQueue | ( | const nkMemory::StringView & | name | ) |
Updates the rendering queue. Used internally in the rendering process.
name | The name of the queue to use. |
void nkGraphics::RenderQueueManager::updateRenderingQueue | ( | RenderQueue * | fromThisOne | ) |
Updates the rendering queue. Used internally in the rendering process.
fromThisOne | The queue to use as a basis to update. |
RenderQueue* nkGraphics::RenderQueueManager::getComputedRenderingQueue | ( | ) | const |